<?php
	if(isset($_SESSION['user']))
	{
		alert("You can't register while you are logged in!");
		redirect("?page=profile");
	}
?>

<div class="cttitle">
	Register
</div>
<div class="content">

	<div class="registeroutput"></div>

	<div class="registerform">
		<form method="POST" action="?page=register&action=register" name="mlgregister" autocomplete="off">
			<table class="register">
				<tr><td>Username:</td><td><input type="text" placeholder="Username" name="username"></td></tr>
				<tr><td>E-Mail:</td><td><input type="text" placeholder="example@internet.com" name="email"></td></tr>
				<tr><td colspan="2">&nbsp;</td></tr>
				<tr><td>Password:</td><td><input type="password" placeholder="password" name="password1" autocomplete="off"></td></tr>
				<tr><td>Repeat:</td><td><input type="password" placeholder="repeat password" name="password2" autocomplete="off"></td></tr>
				<tr><td colspan="2">&nbsp;</td></tr>
				<tr><td>First Name:</td><td><input type="text" placeholder="Connor" name="fname"></td></tr>
				<tr><td>Last Name:</td><td><input type="text" placeholder="Daluty" name="lname"></td></tr>
				<tr><td colspan="2">&nbsp;</td></tr>
				<tr><td>Char Name:</td><td><input type="text" placeholder="TinkyWinky" name="cname"></td></tr>
				<tr><td>Character:</td><td>
					<div class="choice">
						<img class="charpic" src="img/characters/flutter.png">
						<input type="radio" value="1" name="character" checked>
					</div>
					<div class="choice">
						<img class="charpic" src="img/characters/pinkie.png"><br>
						<input type="radio" value="2" name="character">
					</div>
					<div class="choice">
						<img class="charpic" src="img/characters/rainbow.png"><br>
						<input type="radio" value="3" name="character">
					</div>
					<div class="choice">
						<img class="charpic" src="img/characters/twilight.png"><br>
						<input type="radio" value="4" name="character">
					</div>
				</td></tr>
				<tr><td colspan="2">&nbsp;</td></tr>
				<tr><td>&nbsp;</td><td><button class="registerbtn">Register</button></td></tr>
			</table>
		</form>
	</div>

</div>